package com.wyh.domain.dto.gfive;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class LoginBody {
    /**
     * 账户名
     */
    @ApiModelProperty("账户名")
    private String account;
    /**
     * 账户密码
     */
    @Size(max = 20)
    @ApiModelProperty("账户密码")
    @Length(min = 5, max = 20)
    private String password;

    /**
     * 电话
     */

    @ApiModelProperty("电话")
    @Pattern(regexp = "^1\\d{10}$", message = "输入电话号码格式不对")
    private String telephone;
    /**
     * 验证码
     */

    @ApiModelProperty("验证码")
    private int captcha;

}
